<include file="public:header"/>
<include file="public:left"/>
<style>
    td{text-align:center;}
</style>
<section>
    <div class="page_title">
        <h2 class="fl" style="padding-right: 20px">退款列表</h2>
        <form action="" >
            <input type="text" class="page_title_input" name="keyword" placeholder="可搜索会员资料" value="{$keyword}">
            状态
            <select name="status">
                <option value="">全部状态</option>
                <option value="0" <eq name="status" value="0">selected </eq>>审核中</option>
                <option value="1" <eq name="status" value="1">selected </eq>>已退款</option>
                <option value="-1" <eq name="status" value="-1">selected </eq>>拒绝退款</option>
            </select>
            <input  class="page_title_submit" type="submit" value="搜索">
        </form>
        <a class="fr" href="{:url('goods/post')}">添加订单</a>
    </div>
    <table class="table">
        <tr>
            <th>ID</th>
            <th>会员资料</th>
            <th>金额</th>
            <th>状态</th>
            <th>理由</th>
            <th>描述</th>
            <th>申请时间</th>
            <th>操作</th>
        </tr>
        <volist name="list" id="vo">
            <tr>
                <td>{$vo.id}</td>
                <td>{$vo.nickname} {$vo.mobile}</td>
                <td>{$vo.money}</td>
                <td><switch name="vo.status">
                    <case value="-1">已拒绝</case>
                    <case value="0">待审核</case>
                    <case value="1">已退款</case>
                </switch></td>
                <td>{$vo.reason}</td>
                <td>{$vo.des}</td>
                <td>{$vo.create_time|date="Y-m-d H:i:s",###}</td>
                <td>
                    <a href="{:url('order/detail',array('id'=>$vo['order_id']))}" class="inner_btn">查看订单详情</a>

                    <eq name="vo.status" value="0">
                    <a onclick="return confirm('确定拒绝？')"  href="{:url('order/pay',array('id'=>$vo['id'],'status'=>-1))}" class="inner_btn">拒绝通过</a>
                    <a onclick="return confirm('通过后钱会回到客户微信，且无法恢复，确定通过？')" href="{:url('order/pay',array('id'=>$vo['id'],'status'=>1))}" class="inner_btn">申请通过</a>
                    </eq>
                       </td>
            </tr>
        </volist>

    </table>

{$list->render()}
</section>

<!--tabStyle-->
<script>
    $(document).ready(function(){
        //tab
        $(".admin_tab li a").click(function(){
            var liindex = $(".admin_tab li a").index(this);
            $(this).addClass("active").parent().siblings().find("a").removeClass("active");
            $(".admin_tab_cont").eq(liindex).fadeIn(150).siblings(".admin_tab_cont").hide();
        });
    });
</script>


</div>
</section>
</body>
</html>
